package com.rabbit.eap.config.properties;

import lombok.Data;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;

/**
 * @projectName eap
 * @packageName com.rabbit.eap.config.properties
 * @className EapStaticProperties
 * @author： rabbit
 * @version： 1.0
 * @since： 2020/4/17 22:51
 * <p>Description: EapStaticProperties
 * 配置文件属性映射为静态属性
 * </p>

 */
@Slf4j
@Data
@Component
public class EapStaticProperties {
    public static String INFO_PROJECT_VERSION = "";

    @Value("${info.project-version}")
    private String infoProjectVersion;

    @PostConstruct
    public void init() {
        INFO_PROJECT_VERSION = this.infoProjectVersion;
        log.debug("INFO_PROJECT_VERSION:" + INFO_PROJECT_VERSION);
    }
}
